package com.hzncc.flowable_diboot.trial_contracts.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.diboot.core.binding.query.BindQuery;
import com.diboot.core.binding.query.Comparison;
import com.diboot.core.entity.BaseModel;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Length;

import jakarta.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
* 试用合同项目 Entity 定义
* @author MyName
* @version 1.0
* @date 2024-10-16
* Copyright © MyCorp
*/

@TableName("mdl_trial_contract_item")
@Getter @Setter @Accessors(chain = true)
public class TrialContractItem extends BaseModel {
    private static final long serialVersionUID = 1195887732367455575L;

    /**
     * 租户
     */
    @NotNull(message = "租户不能为空")
    @TableField()
    private String tenantId;

    /**
     * 系统名称
     */
    @Length(max=100, message="系统名称长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String systemName;

    /**
     * 系统型号
     */
    @Length(max=100, message="系统型号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String systemType;

    /**
     * 系统生产商
     */
    @Length(max=100, message="系统生产商长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String systemMaker;

    /**
     * 数量
     */
    @TableField()
    private Long number;

    /**
     * 单价
     */
    @TableField()
    private BigDecimal price;

    /**
     * 合计
     */
    @TableField()
    private BigDecimal totalPrice;

    /**
     * 备注
     */
    @Length(max=200, message="备注长度应小于200")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String remark;

    /**
     * 合同id
     */
    @Length(max=32, message="合同id长度应小于32")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String trialContractId;


}